<template >
  <div class="box-x">
    <div class="box-a">
      <div class="nav clearfix">
        <div class="icon">
          <img src="/img/logo_mi.png" alt="">
        </div>
        <div class="title">
           <h2>我的购物车</h2>
          <p>温馨提示：产品是否购买成功，以最终下单为准哦，请尽快结算</p> 
        </div>
        <div class="info clearfix">
          <span class="p1"  @mouseenter="move(-1)" @mouseleave="move(1)">
           <router-link to="#">用户账号</router-link> 
            <img v-if="show" src="@/assets/xia.png" alt="" style="margin-left:5px;" >
          <img v-else src="@/assets/xiaa.png" alt="" style="margin-left:5px;width:16px">
          <ul class="move">
            <li><router-link to="#">
              个人中心
              </router-link>
              </li>
            <li>
             <router-link to="#">
              晒单评价
              </router-link>
              </li>
            <li>
               <router-link to="#">
              我的喜欢
              </router-link>
              </li>
            <li>
              <router-link to="#">
              小米账号
              </router-link>
              </li>
            <li>
               <router-link to="#">
              退出登录
              </router-link>
              </li>
          </ul>
          </span>
          <p  id="border" ></p> 
          <span class="p2"><router-link to="#">我的订单</router-link></span>
        </div>
      </div>
    </div>
    <div class="box-b clearfix" >
      <div class="checkbox">选择</div>
      <div class="image">图片</div>
      <div class="pname">商品名称</div>
      <div class="price">单价</div>
      <div class="count">数量</div>
      <div class="sub">小计</div>
      <div class="err">操作</div>
    </div>
    <div class="box-c"></div>
    <div class="box-d"></div>
  </div>
</template>
<style scoped>
/* 背景 */
.box-x{
 background-color:#f9f9f9; ;
}
/* 清除浮动 */
.clearfix:after{
  content: "";
  display: block;
  height: 0;
  clear: both;
  visibility: hidden;
}
 .box-a{
      background-color: #Ffff;
   width: 100%;
    height: 100PX;
    border-bottom: 2px solid #ff6700;
 }
 .box-a>.nav{
   width: 1200px;
  
   height: 100%;
   margin: 0 auto;
 }
 /* 图片 */
  .box-a>.nav>.icon{
  float: left;
  align-items: center;
    width: 48px;
    margin-top: 26px;
    margin-right: 40px;
  }
 .box-a>.nav>.icon>img{
 width: 100%;

 }
 /* 标题 */
 .box-a>.nav>.title{
   margin-top: 36px;
   float: left;
   display: flex;
   justify-content: center;
 }
  .box-a>.nav>.title>h2{
    color: #424242;
   
    font-size: 28px;
  }
  .box-a>.nav>.title>p{
     margin-top: 12px;
     margin-left: 10px;
     color: #757575;
     font-size: 10px;
  }
 /* 用户信息 */
  .box-a>.nav>.info{
    float: right;
    display: flex;
    justify-content: right;
  }
  .box-a>.nav>.info>span,span,#border{
     margin-top: 50px;
     margin-left: 17px;
       color: #757575;
     font-size: 10px;
     display: inline-block;
      
  }
   .box-a>.nav>.info>.p1:hover{
     color: #ff6700 ;
     cursor: pointer;
   }
    .box-a>.nav>.info>.p2:hover{
       color: #ff6700 ;
     cursor: pointer;
    }
  .box-a>.nav>.info>#border{
     height: 17px;
    border-right: 1px solid #757575 ;
    margin-left: 10px;
  }
 /* 下拉列表 */
  .box-a>.nav>.info .move{
  display: none;
  height:140px;
    background-color: #f9f9f9;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    width: 90px;
  }
 .box-a>.nav>.info .move>li{
   margin-top: 14px;
 }
  .box-a>.nav>.info .move>li:hover{
    background-color: #f1f1f1
  }
  .box-a>.nav>.info>.p1:hover .move{
    display:block; 
     
  }
  .box-a>.nav>.info>.p1>a{
    color: #757575;
   
  }
  .box-a>.nav>.info>.p1{
    width: 90px;
  }
   .box-a>.nav>.info>.p1>a:hover{
     color:#ff6700 ;
   }
   .box-a>.nav>.info>.p2>a{
      color: #757575
   }
    .box-a>.nav>.info>.p2>a:hover{
      color: #ff6700;
    }
   /* 下拉菜单 的颜色*/
     .box-a>.nav>.info>.p1>.move>li>a{
        color: #757575;
       font-size: 10px;
        
     }
       .box-a>.nav>.info>.p1>.move>li>a:hover{
         color:#ff6700 ;
       }
       /* 商品列表 */
        .box-x>.box-b{
          width: 1200px;
            margin:38px  auto;
            background-color: #fff;
            border-bottom: 1px solid #757575;
           
        }
       .box-x>.box-b>div{
         float: left;
          height: 70px;
          text-align: center;
          line-height: 70px;
         
       }
       /* 选择*/
        .box-x>.box-b>.checkbox{
          width: 100px;
          background-color: #ff6700;
        }
        /* 图片 */
          .box-x>.box-b>.image{
            width: 120px;
            background-color: aqua;
          }
          /* 商品名称 */
           .box-x>.box-b>.pname{
             width: 370px;
             background-color: blue;
           }
          /* 单价 */
            .box-x>.box-b>.price{
              width: 150px;
              background-color: burlywood;
            }
            /* 数量 */
              .box-x>.box-b>.count{
                width: 150px;
              }
              /* 小计 */
                .box-x>.box-b>.sub{
                  width: 200px;
                  background-color: chartreuse;
                }
                /* 操作 */
                  .box-x>.box-b>.err{
                    width: 80px;
                    margin-right: 30px;
                  }
</style>
<script>

export default {
    data() {
      return {
        show:true
      }
    },
    methods:{
      //箭头的颜色变化
      move(event){
        if(event<0){
           this.show=false
        }else{
          this.show=true
        }
      
      }
    }
}
</script>